<%@page import="vo.Advertise"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html class="no-js" lang="zxx">
    <head>
        <meta charset="utf-8">
        <meta http-equiv="x-ua-compatible" content="ie=edge">
        <title>商家修改广告</title>
        <meta name="description" content="">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <link rel="manifest" href="site.webmanifest">
		<link rel="shortcut icon" type="image/x-icon" href="img/favicon.ico">
        <!-- Place favicon.ico in the root directory -->

		<!-- CSS here -->
        <link rel="stylesheet" href="css/bootstrap.min.css">
        <link rel="stylesheet" href="css/owl.carousel.min.css">
        <link rel="stylesheet" href="css/animate.min.css">
        <link rel="stylesheet" href="css/nice-select.css">
        <link rel="stylesheet" href="css/themify-icons.css">
        <link rel="stylesheet" href="css/magnific-popup.css">
        <link rel="stylesheet" href="css/meanmenu.css">
		<link rel="stylesheet" href="css/fontawesome-all.min.css">
		<link rel="stylesheet" href="css/slick.css">
		<link rel="stylesheet" href="css/default.css">
		<link rel="stylesheet" href="css/style.css">
		<link rel="stylesheet" href="css/responsive.css">
	</head>
    <body>
		<jsp:useBean id="user" class="vo.Person" scope="session"></jsp:useBean>
		<jsp:useBean id="ad" class="vo.Advertise" scope="session"></jsp:useBean>
		<%
		if(user.getUser_name()==null){
			response.getWriter().println("<script LANGUAGE='javascript'> alert('请先登录！');</script>");
			response.sendRedirect("register.jsp");
		}
		%>
		<!-- header-start -->
		<header>
			<div id="sticky-header" class="header-top-area header-2 pr-60 pl-60">
				<div class="container-fluid">
					<div class="row">
						<div class="col-xl-3 col-lg-2">
							<!-- 此处添加用户名 -->
							<!-- menu profile quick info -->
				            <div class="profile clearfix">
				              <div class="profile_pic">
				                <img src="images/3.jpg" alt="..." class="img-circle profile_img" style="width:60px; height:60px; border-radius:100%; overflow:hidden;">
				              </div>
				              <div class="profile_info">
				                <a href="store_self_info.jsp"><h5><%=user.getUser_name() %></h5></a>
				              </div>
				            </div>
				           <!-- /menu profile quick info -->
						</div>
						<div class="col-xl-6 col-lg-8">
							<div class="main-menu text-center">
								<nav id="mobile-menu">
									<ul>
										<li><a href="store_index.jsp">主页 </a>

										</li>
										<li class="active"><a href="store_ad.jsp">广告</a></li>
										<li><a href="store_order.jsp">订单</a>

										</li>
										<li><a href="store_dishes_upload.jsp">上传菜品</a>

										</li>
										<li><a href="store_ad_create.jsp">发布广告</a>

										</li>

									</ul>
								</nav>
							</div>
							<div class="mobile-menu"></div>
						</div>
					 <div class="col-xl-3 col-lg-2">
							<div class="header-right f-right d-none d-md-none d-lg-block">
                               <ul>
                                   <!-- 退出登录按钮 -->
                                   <li class="info-bar">
                                   	<a href="UserExitServlet">  
                                   		<img src="images/logout.png" width="40px"  higth="40px"/>                          

                            		</a>	
                          		  </li>
                               </ul>
                           </div>
						</div>

					</div>
				</div>
			</div>
		</header>
		<!-- header-end -->
		
		
		<!-- contact-area-start -->
		<div class="contact-area pb-90">
            <div class="container">
                <div class="row">
                    <div class="col-xl-12">
						<form action="EditAdServlet?id=<%=ad.getAd_id() %>" id="contact-form" method="post">
							<div class="row">
								<div class="col-xl-3 col-md-6">
								<label>广告标题</label>
									<input name="title" value="<%=ad.getTitle() %>" type="text">
								</div>
								<div class="col-md-12 text-center">
								<label>广告内容</label>
									<textarea name="content" cols="30" rows="10"><%=ad.getContent() %></textarea>
									<button type="submit">提交修改</button>
								</div>
							</div>
						</form>
					</div>
				</div>
			</div>
		</div>
        <!-- contact-area-end -->
		<!-- map-area-start -->
		<div class="map-area">
			<div id="contact-map"></div>
		</div>
		<!-- map-area-end -->
		<!-- brand-area-start -->
		<div class="brand-area yellow-bg pt-75 pb-75">
			<div class="container">
				<div class="row justify-content-between">
					<div class="brand-active owl-carousel">
						<div class="col-xl-12">
							<div class="brand-wrapper">
								<div class="brand-img">
									<img src="img/brand/1.png" alt="" />
								</div>
							</div>
						</div>
						<div class="col-xl-12">
							<div class="brand-wrapper">
								<div class="brand-img">
									<img src="img/brand/2.png" alt="" />
								</div>
							</div>
						</div>
						<div class="col-xl-12">
							<div class="brand-wrapper">
								<div class="brand-img">
									<img src="img/brand/3.png" alt="" />
								</div>
							</div>
						</div>
						<div class="col-xl-12">
							<div class="brand-wrapper">
								<div class="brand-img">
									<img src="img/brand/4.png" alt="" />
								</div>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>
		<!-- brand-area-end -->

		<!-- Modal Search -->
        <div class="modal fade" id="search-modal" tabindex="-1" role="dialog" aria-hidden="true">
            <div class="modal-dialog" role="document">
                <div class="modal-content">
                    <form>
                        <input type="text" placeholder="Search here...">
                        <button>
                            <i class="fa fa-search"></i>
                        </button>
                    </form>
                </div>
            </div>
        </div>




		<!-- JS here -->
        <script src="js/vendor/modernizr-3.5.0.min.js"></script>
        <script src="js/vendor/jquery-1.12.4.min.js"></script>
        <script src="js/waypoints.min.js"></script>
        <script src="js/jquery.counterup.min.js"></script>
        <script src="js/bootstrap.min.js"></script>
        <script src="js/owl.carousel.min.js"></script>
        <script src="js/isotope.pkgd.min.js"></script>
        <script src="js/jquery.nice-select.min.js"></script>
        <script src="js/jquery.meanmenu.min.js"></script>
        <script src="js/slick.min.js"></script>
        <script src="js/ajax-form.js"></script>
        <script src="js/wow.min.js"></script>
		<script src="http://ditu.google.cn/maps/api/js?key=AIzaSyBceNl50o3BU6LrsIGJxSL9tKKvqBKIeVs"></script>
        <script src="js/jquery.scrollUp.min.js"></script>
        <script src="js/imagesloaded.pkgd.min.js"></script>
        <script src="js/jquery.magnific-popup.min.js"></script>
        <script src="js/plugins.js"></script>
        <script src="js/main.js"></script>
    </body>
</html>
